package org.example.design.designmode.combination.filedemo;

public class Test {
    public static void main(String[] args) {

        File qq = new File("QQ.exe");
        File wx = new File("WX.exe");

        Folder folder1 = new Folder("办公软件",2);
        File word = new File("word.exe");
        File ppt = new File("ppt.exe");
        File ex = new File("exlue.exe");

        folder1.addChild(word);
        folder1.addChild(ppt);
        folder1.addChild(ex);


        Folder folder2 = new Folder("D盘",1);
        folder2.addChild(qq);
        folder2.addChild(wx);
        folder2.addChild(folder1);
        folder2.show();
        folder2.list();


    }
}
